<template>
  <view class="uc-wrap uc-dynamics-dynamics">
    <view class="g-hotelItem" v-for="(item, index) in 1" :key="index">
      <view class="shop">
        <view class="face">
          <image src="https://my.bziyun.com/static/images/hotelItem-face.png?t=1" mode="aspectFill"></image>
        </view>
        <view class="con">
          <view class="name">沐影科技</view>
          <view class="time">6天前</view>
        </view>
      </view>
      <view class="tags">
        <text class="tag">#酒店案例</text>
      </view>
      <view class="desc">楚雄/MO3酒店安装案例</view>
      <view class="imgs-box">
        <view
          class="img"
          v-for="(itemImg, indexImg) in hotelItemImgs"
          :key="indexImg"
          @click="btnShowHotelItemImgs(hotelItemImgs, indexImg)"
        >
          <image :src="itemImg" mode="aspectFill"></image>
        </view>
      </view>
      <view class="btm">
        <view class="l">
          <view class="face">
            <image src="https://my.bziyun.com/20250619/face-default_1750324928973.png" mode="aspectFill"></image>
          </view>
          1人点赞
        </view>
        <view class="btn">
          <image
            src="@/static/images/hotelItem-icon-1.png"
            mode="widthFix"
            class="uc-icon36"
          ></image
          >分享
        </view>
        <view class="btn" @click="isFinger = !isFinger">
          <image
            src="@/static/images/hotelItem-icon-2-on.png"
            mode="widthFix"
            class="uc-icon36"
            v-if="isFinger"
          ></image>
          <image
            src="@/static/images/hotelItem-icon-2.png"
            mode="widthFix"
            class="uc-icon36"
            v-else
          ></image>
          1
        </view>
      </view>
      <view class="reply">
        <view class="reply-item"><text class="uc-b">微信用户4469：</text>佳佳佳佳</view>
        <view class="more">查看1条评论</view>
      </view>
      <view class="details input-box">
        <view class="face">
          <image src="https://my.bziyun.com/20250619/face-default_1750324928973.png" mode="aspectFill"></image>
        </view>
        <input
          type="text"
          class="uc-input details_input"
          placeholder="简单说说..."
          value=""
          placeholder-class="uc-phColor"
        />
      </view>
    </view>
  </view>
</template>
<script setup>
import { ref } from 'vue';
const current = ref(1);
const showShare = ref(false);
const doNothing = () => {};
const hotelItemImgs = [
  'https://my.bziyun.com/static/styles/images/01.jpg',
  'https://my.bziyun.com/static/styles/images/02.jpg',
  'https://my.bziyun.com/static/styles/images/03.jpg',
  'https://my.bziyun.com/static/styles/images/04.jpg',
  'https://my.bziyun.com/static/styles/images/05.jpg',
  'https://my.bziyun.com/static/styles/images/06.jpg',
  'https://my.bziyun.com/static/styles/images/07.jpg',
  'https://my.bziyun.com/static/styles/images/08.jpg',
  'https://my.bziyun.com/static/styles/images/09.jpg'
];
const isFinger = ref(false);
const btnShowHotelItemImgs = (urls, index) => {
  uni.previewImage({
    current: index,
    urls: urls,
    longPressActions: {
      itemList: ['发送给朋友', '保存图片', '收藏'],
      success: function (data) {
        console.log(
          '选中了第' + (data.tapIndex + 1) + '个按钮,第' + (data.index + 1) + '张图片'
        );
      },
      fail: function (err) {
        console.log(err.errMsg);
      }
    }
  });
};
</script>
